package com.ktjy.ktmall.domain;

import lombok.Data;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import java.math.BigDecimal;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ktjy.common.annotation.Excel;
import com.ktjy.common.core.domain.BaseEntity;

/**
 * 商品SKU管理对象 t_sku_info
 *
 * @author ktjy
 * @date 2025-03-19
 */
@Data
@TableName("t_sku_info")
public class SkuInfo extends BaseEntity {
private static final long serialVersionUID=1L;

        /** 主键id */
            @TableId(value = "id" , type = IdType.AUTO)
        private Long id;

        /** 商品表id */
                @Excel(name = "商品表id")
            @TableField(value = "goods_id")
        private Long goodsId;

        /** sku编码 */
                @Excel(name = "sku编码")
            @TableField(value = "stock_sku")
        private String stockSku;

        /** 当前价格 */
                @Excel(name = "当前价格")
            @TableField(value = "price")
        private BigDecimal price;

        /** 原价 */
                @Excel(name = "原价")
            @TableField(value = "old_price")
        private BigDecimal oldPrice;

        /** 库存数量 */
                @Excel(name = "库存数量")
            @TableField(value = "inventory")
        private Long inventory;

        /** 商品图片 */
                @Excel(name = "商品图片")
            @TableField(value = "picture")
        private String picture;

        /** 状态 */
                @Excel(name = "状态")
            @TableField(value = "status")
        private Long status;

        /**商品名称*/
        @TableField(exist = false)
        private String goodsName;


@Override
public String toString(){
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("id" ,getId())
        .append("goodsId" ,getGoodsId())
        .append("stockSku" ,getStockSku())
        .append("price" ,getPrice())
        .append("oldPrice" ,getOldPrice())
        .append("inventory" ,getInventory())
        .append("picture" ,getPicture())
        .append("status" ,getStatus())
        .append("createTime" ,getCreateTime())
        .append("updateTime" ,getUpdateTime())
        .append("createBy" ,getCreateBy())
        .append("updateBy" ,getUpdateBy())
        .append("remark" ,getRemark())
            .append("goodsName" ,getGoodsName())
            .toString();
}
        }